﻿using BCCommon.Enums;
using BCEntity.Sim.CompanyBelongArea;
using System;
using System.Collections.Generic;
using System.Text;
using System.Threading.Tasks;

namespace BCData.Sim.CompanyBelongArea
{
    /// <summary>
    /// 集团公司归属区域
    /// </summary>
    public interface ICompanyBelongAreaData
    {
        /// <summary>
        /// 获取集团公司归属区域
        /// </summary>
        /// <param name="companyId">集团公司Id</param>
        /// <returns></returns>
        Task<IEnumerable<CompanyBelongAreaEntity>> Query(int companyId);
        /// <summary>
        /// 获取集团其他公司已设置的归属区域列表
        /// </summary>
        /// <param name="companyId">集团公司Id</param>
        /// <returns></returns>
        Task<IEnumerable<CompanyBelongAreaEntity>> OtherBelongArea(int companyId);
        /// <summary>
        /// 设置集团公司归属区域
        /// </summary>
        /// <param name="insertList">添加归属列表</param>
        /// <param name="deleteList">移除归属列表</param>
        /// <returns></returns>
        Task<int> SettingBelongArea(List<CompanyBelongAreaEntity> insertList, List<CompanyBelongAreaEntity> deleteList);
        /// <summary>
        /// 获取归属区域公司
        /// </summary>
        /// <param name="provinceCode">省份编码</param>
        /// <param name="cityCode">城市编码</param>
        /// <param name="companyBusinessType">公司类型</param>
        /// <returns></returns>
        Task<CompanyBelongAreaEntity> GetBelongAreaCompany(string provinceCode, string cityCode, CompanyBusinessType? companyBusinessType);
    }
}
